﻿using System;
using System.Collections.Generic;
using System.ComponentModel;
using System.Data;
using System.Drawing;
using System.Linq;
using System.Text;
using System.Windows.Forms;

namespace QualityStorm {
    public partial class FrmSelectOPCServer : Form {

        
        public string MachineName {
            set {
                this.Text = this.Text + " " + value;
            }
        }

        public string ServerName {
            get {
                return lstServers.SelectedItem.ToString();
            }
        }

        public Array Servers {
            set {
                foreach (string server in value) {
                    lstServers.Items.Add(server);
                }
            }
        }
        public FrmSelectOPCServer() {
            InitializeComponent();
        }

        private void FrmSelectOPCServer_Load(object sender, EventArgs e) {
            
        }

        private void lstServers_SelectedIndexChanged(object sender, EventArgs e) {
            btnOK.Enabled = lstServers.SelectedIndex != -1;
        }
    }
}
